Blueprint Help Send comments on this topic.
Splitting Compound Collected Events

Glossary Item Box

Overview

There are two main reasons for collecting events together:

  1. An active object may require information from multiple events (such as a read buffer from one store and a write buffer from another store)
  2. It may be necessary to delay an event until others have arrived (i.e. synchronize events)

In the first case, all of the collected events are implicitly required and therefore the compound event is used to trigger an active object directly.  However, in the second case it may be that just one event is required and any other events are just for synchronization purposes.  The splitting operation causes a compound input event to be split back into its component parts, allowing individual events to be passed onwards.

How is Splitting Provided by CLIP?

CLIP provides a nodal object called a Splitter:

The splitter object must be connected to a compound event that contains a collection and it will split the first collection found in the tree.  The connections on the splitter are associated by labels with the connections on the collector:

The example above illustrates a simple splitting operation.  MethodX receives a compound event containing the store and semaphore events, MethodY only receives the store event, and MethodZ only receives the semaphore event.

The Reasons for Splitting

Splitting is useful for three primary reasons:

  • It reduces the size of the event being passed around, which can improve performance in distributed systems
  • It allows an event to be modified so that it can be passed into a component with a pre-defined interface
  • It allows events to be synchronized but kept separate

This second point is crucial for building re-usable component libraries.  For example, consider the case where we have a library component that requires a single transient store as its input:

and a compound event containing a semaphore and a store, where we want to pass the data into the library

The above diagram shows the collected event being passed directly into the library component but this is illegal because the library component is expecting to receive an event containing just a transient store at its root.  In order to resolve this problem, we must split the collected event and pass through the particular component that is required (the transient store in this case):

Implicit Transparency

The splitter object introduces the notion of implicit transparency.  As a result of the output link of the splitter containing the event that was received on the corresponding link of its paired collector, the output event cannot contain any information about the splitter, collector, or any of the objects between the two.  These objects are referred to as implicitly transparent, meaning that the ultimate consumer cannot 'see' them when examining its received event.